#-------------------------------------------------------------------------------
# Name:        module1
# Purpose:
#
# Author:      slha
#
# Created:     21/08/2012
# Copyright:   (c) slha 2012
# Licence:     <your licence>
#-------------------------------------------------------------------------------
#!/usr/bin/env python

tbids = ['UTHA01', 'UTHA02', 'UTHA03', 'UTHA04', 'UTHA05', 'UTHA06', 'UTHA07', 'UTHA08', 'UTHA09', 'UTHA10', 'UTHA11', 'UTHA12',
           'UTHB01', 'UTHB02', 'UTHB03', 'UTHB04', 'UTHB05', 'UTHB06', 'UTHB07', 'UTHB08', 'UTHB09', 'UTHB10', 'UTHB11', 'UTHB12', 'UTHB13', 'UTHB14',
           'UTHC01', 'UTHC02', 'UTHC03', 'UTHC04', 'UTHC05', 'UTHC06', 'UTHC07', 'UTHC08', 'UTHC09', 'UTHC10', 'UTHC11', 'UTHC12', 'UTHC13', 'UTHC14', 'UTHC15',
           'UTHD01', 'UTHD02', 'UTHD03', 'UTHD04', 'UTHD05', 'UTHD06', 'UTHD07', 'UTHD08', 'UTHD09', 'UTHD10', 'UTHD11', 'UTHD12', 'UTHD13', 'UTHD14', 'UTHD15', 'UTHD16', 'UTHD17',
           'UTHE01', 'UTHE02', 'UTHE03', 'UTHE04', 'UTHE05', 'UTHE06', 'UTHE07', 'UTHE08', 'UTHE09', 'UTHE10', 'UTHE11', 'UTHE12', 'UTHE13', 'UTHE14', 'UTHE15', 'UTHE16', 'UTHE17',
           'UTHF01', 'UTHF02', 'UTHF03', 'UTHF04', 'UTHF05', 'UTHF06', 'UTHF07', 'UTHF08', 'UTHF09', 'UTHF10', 'UTHF11', 'UTHF12', 'UTHF13', 'UTHF14',
           'UTHG01', 'UTHG02', 'UTHG03', 'UTHG04', 'UTHG05', 'UTHG06', 'UTHG07', 'UTHG08', 'UTHG09', 'UTHG10', 'UTHG11']


row_a = ['UTHA%02d' %  d  for d in range(1,13,1)]
row_e = ['UTHE%02d' %  d  for d in range(17,0,-1)]
row_d = ['UTHD%02d' %  d  for d in range(17,0,-1)]
row_f = ['UTHF%02d' %  d  for d in range(14,0,-1)]
row_g = ['UTHG%02d' %  d  for d in range(1,12,1)]



#
# Vtable allows standardisation of variable names
#
vtable = {'WindSpeed':       'WindSpeed',
          'ActivePower':     'ActivePower',
          'BladePitchAngle': 'BladePitchAngle'}


def front_row(d):
    if (d>0 ) & (d<=90):
        tbs = ['UKFF02', 'UKFF03', 'UKFF04']

    elif (d>90) & (d<=180):
        tbs = ['UKFB05', 'UKFC05', 'UKFD05']

    elif (d>180) & (d<=270):
        tbs = ['UKFA02', 'UKFA03', 'UKFA04']

    else:
        tbs = ['UKFB01', 'UKFC01', 'UKFD01']